
// 数据类型定义
export interface ResponseData {
   code: number,
   message: string,
   ok: boolean
}
// 菜单数据和按钮数据的ts类型
export interface PermissionData {
   id?: number,
   createTime: string,
   updateTime: string,
   pid: number,
   name: string,
   code: null,
   toCode: null,
   type: number,
   status: null,
   level: number,
   children?: PermissionDataList,
   select: boolean
}
export type PermissionDataList = PermissionData[]
// 获取菜单接口返回数据的ts类型
export interface AllPermissionResponseData extends ResponseData {
   data: PermissionDataList
}

// 添加与修改菜单携带的参数类型
export interface MenuParams {
   id?: number,//添加菜单id
   code: string,//权限数值
   level: number,//几级菜单
   name: string,//菜单名字
   pid: number //父级菜单id
}